home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / pcr / pcr4_4.lha / DIST / threads / ThreadsInit0.c < prev    next >
C/C++ Source or Header  |  1990-11-13  |  1KB  |  42 lines

  1. /* begincopyright
  2.   Copyright (c) 1988 Xerox Corporation. All rights reserved.
  3.   Use and copying of this software and preparation of derivative works based
  4.   upon this software are permitted. Any distribution of this software or
  5.   derivative works must comply with all applicable United States export
  6.   control laws. This software is made available AS IS, and Xerox Corporation
  7.   makes no warranty about the software, its performance or its conformity to
  8.   any specification. Any person obtaining a copy of this software is requested
  9.   to send their name and post office or electronic mail address to:
  10.     PCR Coordinator
  11.     Xerox PARC
  12.     3333 Coyote Hill Rd.
  13.     Palo Alto, CA 94304
  14.   endcopyright */
  15.  
  16. /*
  17.  * ThreadsInit.c
  18.  *
  19.  * Demers, November 13, 1990 2:11:23 pm PST
  20.  *
  21.  * Xerox Runtime threads package pre-initialization.
  22.  *
  23.  * This file calls XR_setjmp, so it should not be optimized.
  24.  */
  25.  
  26. #include "xr/Threads.h"
  27.  
  28.  
  29. void
  30. XR_InitAndRun()
  31. {
  32.     extern struct XR_JmpBufRep XR_finalCleanupJmpBuf;
  33.     extern void XR_FinalCleanup();
  34.     extern void XR_InitAndRunInner();
  35.     int xStatus;
  36.     
  37.     if( (xStatus = XR_setjmp(&XR_finalCleanupJmpBuf)) == 0 )
  38.         XR_InitAndRunInner();
  39.     XR_FinalCleanup(xStatus);
  40.     /*NOTREACHED*/
  41. }
  42.